package com.example.demo.model.entity;

import javax.persistence.*;
import java.math.BigDecimal;

@Entity
@Table(name = "t_balance")
public class BalanceModel {

    @Id
    @Column
    private String balanceId;

    @Column
    private String userId;

    @Column
    private Long createTime;

    @Column
    private BigDecimal balance;

    @Column
    private String balanceDesc;

    @Column
    private String productId;

    @Column
    private String handlerUid;

    @Column
    private String handlerUsername;

    @Column
    private BigDecimal money;

    @OneToOne
    @JoinColumn(name = "userId", insertable = false, updatable = false)
    private UserModel user;

    public BigDecimal getMoney() {
        return money;
    }

    public void setMoney(BigDecimal money) {
        this.money = money;
    }

    public String getHandlerUid() {
        return handlerUid;
    }

    public void setHandlerUid(String handlerUid) {
        this.handlerUid = handlerUid;
    }

    public String getHandlerUsername() {
        return handlerUsername;
    }

    public void setHandlerUsername(String handlerUsername) {
        this.handlerUsername = handlerUsername;
    }

    public String getProductId() {
        return productId;
    }

    public void setProductId(String productId) {
        this.productId = productId;
    }

    public UserModel getUser() {
        return user;
    }

    public void setUser(UserModel user) {
        this.user = user;
    }

    public String getBalanceId() {
        return balanceId;
    }

    public void setBalanceId(String balanceId) {
        this.balanceId = balanceId;
    }

    public String getUserId() {
        return userId;
    }

    public void setUserId(String userId) {
        this.userId = userId;
    }

    public Long getCreateTime() {
        return createTime;
    }

    public void setCreateTime(Long createTime) {
        this.createTime = createTime;
    }

    public BigDecimal getBalance() {
        return balance;
    }

    public void setBalance(BigDecimal balance) {
        this.balance = balance;
    }

    public String getBalanceDesc() {
        return balanceDesc;
    }

    public void setBalanceDesc(String balanceDesc) {
        this.balanceDesc = balanceDesc;
    }
}
